package com.gmail.dukenukemshawn12;

import org.bukkit.Material;
import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.player.PlayerMoveEvent;
import org.bukkit.plugin.Plugin;

public class Step implements Listener{
	public Step(Plugin pl){
		this.pl = pl;
	}
	private Plugin pl;
	@EventHandler
	public void playerStep(PlayerMoveEvent event){
		Player player = event.getPlayer();
		if(player.getLocation().getBlock().getType().equals(Material.WEB)){
			//See if this sits.
			boolean d;
			pl.getServer().getScheduler().scheduleSyncRepeatingTask(pl, new Damage(player), 21l, 40l);
		}
	}
}
